package com.twxm.breed.entity;

import com.baomidou.mybatisplus.annotation.TableId;
import com.gitee.sunchenbin.mybatis.actable.annotation.Column;
import com.gitee.sunchenbin.mybatis.actable.annotation.IsKey;
import com.gitee.sunchenbin.mybatis.actable.annotation.IsNotNull;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.Table;

@Data
@Table(name = "department")
public class Department {

    @IsKey
    @TableId
    @Column(comment = "部门编号")
    private int id;

    @Column(comment = "部门名称")
    @IsNotNull
    private String name;

    public Department(int id, String name) {
        this.id = id;
        this.name = name;
    }
}
